Added wfProfileOut for early returns in ResourceLoaderModule::getDefinitionMtime
authorOri Livneh <ori@wikimedia.org>
Tue, 3 Dec 2013 06:10:44 +0000 (22:10 -0800)
committerOri Livneh <ori@wikimedia.org>
Tue, 3 Dec 2013 06:10:44 +0000 (22:10 -0800)
I added the profiling calls in PS13 of I00cf086c9 but forgot to add
wfProfileOuts for the early returns.

Change-Id: Ibcd22daba8da0e087376553bca271796e0d207e5

includes/resourceloader/ResourceLoaderModule.php

index 26092af..db84dcf 100644 (file)
@@ -448,6 +448,7 @@ abstract class ResourceLoaderModule {
                wfProfileIn( __METHOD__ );
                $summary = $this->getDefinitionSummary( $context );
                if ( $summary === null ) {
+                       wfProfileOut( __METHOD__ );
                        return 0;
                }
 
@@ -469,6 +470,7 @@ abstract class ResourceLoaderModule {
                $data = $cache->get( $key );
                if ( is_int( $data ) && $data > 0 ) {
                        // We've seen this hash before, re-use the timestamp of when we first saw it.
+                       wfProfileOut( __METHOD__ );
                        return $data;
                }